﻿<ResourceDictionary xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    xmlns:gc="clr-namespace:WickedFlame.VecDraw.Base.Controls">

    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="/VecDraw.Base;component/Resources/CtrlBrushes.xaml"/>
    </ResourceDictionary.MergedDictionaries>
    
    <!--SelectionButton-->
    <Style TargetType="{x:Type gc:SelectableButton}">
        <!--<Setter Property="Margin" Value="5,5,5,5"/>-->
        <Setter Property="Control.Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type gc:SelectableButton}">
                    <Border SnapsToDevicePixels="True" BorderBrush="Transparent" BorderThickness="1,1,1,1" CornerRadius="0" Background="Transparent" Name="btnBorder">
                        <Grid>
                            <Grid.ColumnDefinitions>
                                <ColumnDefinition Width="Auto"/>
                                <ColumnDefinition/>
                            </Grid.ColumnDefinitions>

                            <ContentPresenter x:Name="Icon"
                                                  Grid.Column="0"
													VerticalAlignment="Center"
													ContentSource="Icon"
                                                    HorizontalAlignment="Left"
                                                  Margin="5,0,10,0"
													SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>

                            <TextBlock Text="{TemplateBinding Title}" Grid.Column="1" VerticalAlignment="Center"/>
                            <!--</Viewbox>-->

                        </Grid>
                    </Border>

                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="true">
                            <Setter Property="BorderBrush" Value="#20FFFFFF" TargetName="btnBorder" /><!--#FF565656-->
                            <Setter Property="Background" Value="#20FFFFFF" TargetName="btnBorder"/>
                        </Trigger>
                        <Trigger Property="IsPressed" Value="true">
                            <Setter Property="BorderBrush" Value="#20FFFFFF" TargetName="btnBorder" />
                            <Setter Property="Background" Value="#20FFFFFF" TargetName="btnBorder"/>
                        </Trigger>
                        <Trigger Property="IsSelected" Value="true">
                            <Setter Property="BorderBrush" Value="#20FFFFFF" TargetName="btnBorder" />
                            <Setter Property="Background" Value="#30FFFFFF" TargetName="btnBorder"/>
                        </Trigger>
                    </ControlTemplate.Triggers>

                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>
</ResourceDictionary>